package com.example.mangroves.service.impl;

import com.example.mangroves.entity.GeoDetails;
import com.example.mangroves.mapper.GeoDetailMapper;
import com.example.mangroves.service.GeoDetailService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;

@Service
public class GeoDetailServiceImpl implements GeoDetailService {

    @Autowired
    private GeoDetailMapper geoDetailMapper;

    @Override
    public void saveGeoDetail(GeoDetails geoDetail) {
        geoDetailMapper.insertGeoDetail(geoDetail);
    }

    public List<GeoDetails> getGeoDetailsByGeoInfoId(int geoInfoId) {
        return geoDetailMapper.findGeoDetailsByGeoInfoId(geoInfoId);
    }
}

